package by.ostrovsky.webhousingsystem.bean.user;

import org.apache.struts2.ServletActionContext;

import by.ostrovsky.webhousingsystem.constants.Constants;

import com.opensymphony.xwork2.ActionSupport;

@SuppressWarnings("serial")
public class LogoutAction extends ActionSupport{

	@Override
	public String execute() {
		try {
			ServletActionContext.getRequest().getSession(true).invalidate();
		} catch (Exception e) {
			LOG.error(ERROR, e);
		}
		return Constants.SUCCESS;
	}
}
